package com.yfl.service.impl;

import com.yfl.domain.SysUser;
import com.yfl.mapper.SysUserMapper;
import com.yfl.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * 用户接口的实现类
 */
@Service
public class UserServiceImpl implements UserService {

    @Autowired
    private SysUserMapper mapper;

    /**
     * 使用用户名查询用户
     * @param username 用户名称
     * @return 数据库里面的用户对象
     */
    @Override
    public SysUser findUserByUsername(String username) {
        return mapper.selectUserByUsername(username);
    }
}
